import java.awt.*;


public class MissileSprite extends Sprite{

	public boolean loadMissle = true;

	public MissileSprite (int w, int h, ImagesLoader imsLd,String image,int speed){

		super( w, h/2, w, h, imsLd, image);  
		// the ball is positioned in the middle at the panel's rhs
		initPosition(speed);

	}

	public void updateSprite() 
	{ 
		super.updateSprite();
		if (this.locx >= 500 || this.locx <=0 ){
			loadMissle=true;
		}
	}
	private void initPosition(int speed)
	// adjust the fireball's position and its movement left
	{

		setPosition(getPWidth(), getPHeight()); 
		setStep(speed, 0);   // move left
		loadMissle = false;
	} // end of initPosition()
	



}
